import { createRouter, createWebHashHistory } from "vue-router";

import toDoList from "@/pages/todo/index.vue";
import loginPage from "@/pages/login/index.vue";
// 路由路径
const routes = [
  { path: "/", component: loginPage },
  { path: "/home", name: "home", component: toDoList },
  { path: "/login", name: "login", component: loginPage },
];

// 路由实例
const router = createRouter({
  history: createWebHashHistory(),
  routes,
});

export default router;
